
#ifndef TOUCH_H
#define TOUCH_H

#include "stdint.h"

typedef struct
{
    uint8_t (*write_reg)(void *handle, uint8_t addr, uint16_t reg, uint8_t *buff, uint8_t len);
    uint8_t (*read_reg)(void *handle, uint8_t addr, uint16_t reg, uint8_t *buff, uint8_t len);
    void (*reset)(void *handle, uint16_t ms1, uint16_t ms2);
}touch_bus_t;

typedef enum
{
    kTouchEventReleased = 0,
    kTouchEventPressed,
}touch_event_t;

typedef struct
{
    uint16_t x;     
    uint16_t y;     
    uint16_t width;     
    uint8_t track_id; 
    touch_event_t event; 
}touch_data_t;

typedef struct
{
    touch_data_t *point;
    uint8_t point_num;
    uint8_t status;
}touch_base_t;


#endif
